package cn.source.system.controller;

import cn.source.common.annotation.Log;
import cn.source.common.core.controller.BaseController;
import cn.source.common.core.domain.AjaxResult;
import cn.source.common.core.page.TableDataInfo;
import cn.source.common.enums.BusinessType;
import cn.source.system.domain.NavSite;
import cn.source.system.service.INavSiteService;
import lombok.AllArgsConstructor;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.web.bind.annotation.*;

import java.util.List;

/**
 * @program: source-vue
 * @ClassName: NavSiteController
 * @description: 用户导航网站信息Controller
 * @author: 诗涵
 * @create: 2024-02-21 10:13
 */
@RestController
@RequestMapping("/nav/site")
@AllArgsConstructor
public class NavSiteController extends BaseController {
    private final INavSiteService navSiteService;

    /**
     * 查询用户导航网站信息列表
     */
    @PreAuthorize("@ss.hasPermi('nav:site:list')")
    @GetMapping("/list")
    public TableDataInfo list(NavSite navSite)
    {
        startPage();
        List<NavSite> list = navSiteService.selectNavSiteList(navSite);
        return getDataTable(list);
    }
}
